Optimal. Leaf size=231 \[ \frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{h}+\frac {4 b p q \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^3 \text {Li}_2\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\frac {12 b^2 p^2 q^2 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^2 \text {Li}_3\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}+\frac {24 b^3 p^3 q^3 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right ) \text {Li}_4\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\frac {24 b^4 p^4 q^4 \text {Li}_5\left (-\frac {h (e+f x)}{f g-e h}\right )}{h} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.36, antiderivative size = 231, normalized size of antiderivative = 1.00, number of steps
used = 7, number of rules used = 6, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.214, Rules used = {2443, 2481,
2421, 2430, 6724, 2495} \begin {gather*} \frac {24 b^3 p^3 q^3 \text {PolyLog}\left (4,-\frac {h (e+f x)}{f g-e h}\right ) \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )}{h}-\frac {12 b^2 p^2 q^2 \text {PolyLog}\left (3,-\frac {h (e+f x)}{f g-e h}\right ) \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^2}{h}+\frac {4 b p q \text {PolyLog}\left (2,-\frac {h (e+f x)}{f g-e h}\right ) \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^3}{h}-\frac {24 b^4 p^4 q^4 \text {PolyLog}\left (5,-\frac {h (e+f x)}{f g-e h}\right )}{h}+\frac {\log \left (\frac {f (g+h x)}{f g-e h}\right ) \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4}{h} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2421
Rule 2430
Rule 2443
Rule 2481
Rule 2495
Rule 6724
Rubi steps
\begin {align*} \int \frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4}{g+h x} \, dx &=\text {Subst}\left (\int \frac {\left (a+b \log \left (c d^q (e+f x)^{p q}\right )\right )^4}{g+h x} \, dx,c d^q (e+f x)^{p q},c \left (d (e+f x)^p\right )^q\right )\\ &=\frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{h}-\text {Subst}\left (\frac {(4 b f p q) \int \frac {\left (a+b \log \left (c d^q (e+f x)^{p q}\right )\right )^3 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{e+f x} \, dx}{h},c d^q (e+f x)^{p q},c \left (d (e+f x)^p\right )^q\right )\\ &=\frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{h}-\text {Subst}\left (\frac {(4 b p q) \text {Subst}\left (\int \frac {\left (a+b \log \left (c d^q x^{p q}\right )\right )^3 \log \left (\frac {f \left (\frac {f g-e h}{f}+\frac {h x}{f}\right )}{f g-e h}\right )}{x} \, dx,x,e+f x\right )}{h},c d^q (e+f x)^{p q},c \left (d (e+f x)^p\right )^q\right )\\ &=\frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{h}+\frac {4 b p q \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^3 \text {Li}_2\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\text {Subst}\left (\frac {\left (12 b^2 p^2 q^2\right ) \text {Subst}\left (\int \frac {\left (a+b \log \left (c d^q x^{p q}\right )\right )^2 \text {Li}_2\left (-\frac {h x}{f g-e h}\right )}{x} \, dx,x,e+f x\right )}{h},c d^q (e+f x)^{p q},c \left (d (e+f x)^p\right )^q\right )\\ &=\frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{h}+\frac {4 b p q \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^3 \text {Li}_2\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\frac {12 b^2 p^2 q^2 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^2 \text {Li}_3\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}+\text {Subst}\left (\frac {\left (24 b^3 p^3 q^3\right ) \text {Subst}\left (\int \frac {\left (a+b \log \left (c d^q x^{p q}\right )\right ) \text {Li}_3\left (-\frac {h x}{f g-e h}\right )}{x} \, dx,x,e+f x\right )}{h},c d^q (e+f x)^{p q},c \left (d (e+f x)^p\right )^q\right )\\ &=\frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{h}+\frac {4 b p q \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^3 \text {Li}_2\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\frac {12 b^2 p^2 q^2 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^2 \text {Li}_3\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}+\frac {24 b^3 p^3 q^3 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right ) \text {Li}_4\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\text {Subst}\left (\frac {\left (24 b^4 p^4 q^4\right ) \text {Subst}\left (\int \frac {\text {Li}_4\left (-\frac {h x}{f g-e h}\right )}{x} \, dx,x,e+f x\right )}{h},c d^q (e+f x)^{p q},c \left (d (e+f x)^p\right )^q\right )\\ &=\frac {\left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^4 \log \left (\frac {f (g+h x)}{f g-e h}\right )}{h}+\frac {4 b p q \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^3 \text {Li}_2\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\frac {12 b^2 p^2 q^2 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^2 \text {Li}_3\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}+\frac {24 b^3 p^3 q^3 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right ) \text {Li}_4\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}-\frac {24 b^4 p^4 q^4 \text {Li}_5\left (-\frac {h (e+f x)}{f g-e h}\right )}{h}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(1095\) vs. \(2(231)=462\).
time = 0.23, size = 1095, normalized size = 4.74 \begin {gather*} \frac {a^4 \log (g+h x)-4 a^3 b p q \log (e+f x) \log (g+h x)+6 a^2 b^2 p^2 q^2 \log ^2(e+f x) \log (g+h x)-4 a b^3 p^3 q^3 \log ^3(e+f x) \log (g+h x)+b^4 p^4 q^4 \log ^4(e+f x) \log (g+h x)+4 a^3 b \log \left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)-12 a^2 b^2 p q \log (e+f x) \log \left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)+12 a b^3 p^2 q^2 \log ^2(e+f x) \log \left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)-4 b^4 p^3 q^3 \log ^3(e+f x) \log \left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)+6 a^2 b^2 \log ^2\left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)-12 a b^3 p q \log (e+f x) \log ^2\left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)+6 b^4 p^2 q^2 \log ^2(e+f x) \log ^2\left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)+4 a b^3 \log ^3\left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)-4 b^4 p q \log (e+f x) \log ^3\left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)+b^4 \log ^4\left (c \left (d (e+f x)^p\right )^q\right ) \log (g+h x)+4 a^3 b p q \log (e+f x) \log \left (\frac {f (g+h x)}{f g-e h}\right )-6 a^2 b^2 p^2 q^2 \log ^2(e+f x) \log \left (\frac {f (g+h x)}{f g-e h}\right )+4 a b^3 p^3 q^3 \log ^3(e+f x) \log \left (\frac {f (g+h x)}{f g-e h}\right )-b^4 p^4 q^4 \log ^4(e+f x) \log \left (\frac {f (g+h x)}{f g-e h}\right )+12 a^2 b^2 p q \log (e+f x) \log \left (c \left (d (e+f x)^p\right )^q\right ) \log \left (\frac {f (g+h x)}{f g-e h}\right )-12 a b^3 p^2 q^2 \log ^2(e+f x) \log \left (c \left (d (e+f x)^p\right )^q\right ) \log \left (\frac {f (g+h x)}{f g-e h}\right )+4 b^4 p^3 q^3 \log ^3(e+f x) \log \left (c \left (d (e+f x)^p\right )^q\right ) \log \left (\frac {f (g+h x)}{f g-e h}\right )+12 a b^3 p q \log (e+f x) \log ^2\left (c \left (d (e+f x)^p\right )^q\right ) \log \left (\frac {f (g+h x)}{f g-e h}\right )-6 b^4 p^2 q^2 \log ^2(e+f x) \log ^2\left (c \left (d (e+f x)^p\right )^q\right ) \log \left (\frac {f (g+h x)}{f g-e h}\right )+4 b^4 p q \log (e+f x) \log ^3\left (c \left (d (e+f x)^p\right )^q\right ) \log \left (\frac {f (g+h x)}{f g-e h}\right )+4 b p q \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^3 \text {Li}_2\left (\frac {h (e+f x)}{-f g+e h}\right )-12 b^2 p^2 q^2 \left (a+b \log \left (c \left (d (e+f x)^p\right )^q\right )\right )^2 \text {Li}_3\left (\frac {h (e+f x)}{-f g+e h}\right )+24 a b^3 p^3 q^3 \text {Li}_4\left (\frac {h (e+f x)}{-f g+e h}\right )+24 b^4 p^3 q^3 \log \left (c \left (d (e+f x)^p\right )^q\right ) \text {Li}_4\left (\frac {h (e+f x)}{-f g+e h}\right )-24 b^4 p^4 q^4 \text {Li}_5\left (\frac {h (e+f x)}{-f g+e h}\right )}{h} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.21, size = 0, normalized size = 0.00 \[\int \frac {\left (a +b \ln \left (c \left (d \left (f x +e \right )^{p}\right )^{q}\right )\right )^{4}}{h x +g}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\left (a + b \log {\left (c \left (d \left (e + f x\right )^{p}\right )^{q} \right )}\right )^{4}}{g + h x}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {{\left (a+b\,\ln \left (c\,{\left (d\,{\left (e+f\,x\right )}^p\right )}^q\right )\right )}^4}{g+h\,x} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________